<?php
	class xl_load_dl extends datatbase
	{
		function timKiemTen($q)
		{
	$data=array();
	if (!$q) return;
		$sql="select * from nhomdiadiem where TenNhomDiaDiem like N'%".$q."%' order by TenNhomDiaDiem ASC limit 0,10";
		$result = mysql_query($sql);
		while( $rs= mysql_fetch_array($result,MYSQL_ASSOC)){
				$data[]=array("value" =>$rs['TenNhomDiaDiem'],"id"=>$rs['TenNhomDiaDiem']);
			}
		/*$sql = "select * from diadiem where TenDiaDiem like N'%".$q."%' order by TenDiaDiem ASC limit 0,10";
		$rsd = mysql_query($sql);
		while( $rs= mysql_fetch_array($rsd,MYSQL_ASSOC)) {
			$hienthi=$rs['TenDiaDiem'];
			$data[]=array("value" =>$hienthi,"id"=>$rs['TenDiaDiem']);
		}*/
	return $data;
		}
	}
?>